<?php
// +----------------------------------------------------------------------
// | Description: about us
// +----------------------------------------------------------------------
// | Author: orchief
// +----------------------------------------------------------------------
// | Date: 2018-03-06 13:37:11
// +----------------------------------------------------------------------

namespace app\client\controller;

use app\common\controller\ApiCommon;
use think\Db;

class OrderConfigs extends ApiCommon
{
    /**
     * 获取参数列表
     */
    public function index()
    {
        $data = Db::table('shop_config') -> find();
        $this -> jsonData($data);
    }

    /**
     * 修改参数
     */
    public function update()
    {
        $res = Db::table('shop_config') -> where(['Id' => 1]) -> update(['Feight' => $this->param['Feight']]);
        $this->checkRes($res, '修改成功！', '修改失败！');
    }
}
